<template>
        <view class="dao">
			<text @click="onGuideTap(0)" class="he">导航岸芷丁兰美容店</text>
			<text @click="onGuideTap(1)" class="he">导航克丽缇娜</text>
			<text @click="onGuideTap(2)" class="he">导航美鹿田园</text>
			</view>
</template>

<script>
    import { mapMutations, mapState } from 'vuex';
    
    export default {
		data(){
			return {
				name:['岸芷丁兰美容店','克丽缇娜','美鹿田园']
			};
		},
        computed: {
            ...mapState('m-map', ['latitude','longitude'])
        },
        methods: {
            ...mapMutations('m-map', ['update']),
            onGuideTap(e) {
				  if(e===0){
						wx.openLocation({
						    type: 'gcj02',
						    latitude: 35.41408,
						    longitude: 114.066224,
						    name: this.name[0],
						    scale: 18
						})
						 }else if(e===1){
							wx.openLocation({
							    type: 'gcj02',
							    latitude: 35.41408,
							    longitude: 114.066224,
							    name: this.name[1],
							    scale: 18
							})
						}else if(e===2){
							wx.openLocation({
							    type: 'gcj02',
							    latitude: 35.41408,
							    longitude: 114.066224,
							    name: this.name[2],
							    scale: 18
							})
						}
				},
				onload(e){
					this.index=e.index
				}
            }
        }
</script>

<style lang="scss">
	.he{
		border: 1px solid #efefef;
		border-radius: 25%;
		font-size: 20px;
		display: flex;
	}
</style>